<?
include('./header.inc');
include('./database.inc');
include('./pagehead.inc');

$query = "SELECT * FROM slides ORDER BY slide_name ASC";
$result = mysql_query($query);


?>
<table>
	<tr class="headerrow"><th>Slide Name</th><th>Edit</th><th>Delete</th></tr>
	<?
	$counter = 0;
	while($row = mysql_fetch_array($result)){
	?>
	<tr class="<? echo (($counter % 2) == 0 ? "even" : "odd" );?>">
	<td><? echo $row['slide_name'];?></td>
	<td class="edit"><a href="./editslide.php?sid=<? echo $row['slide_id'];?>">edit</a></td>
	<td class="delete"><a onclick="return confirm('Are you sure you want to delete this slide set?')" href="./deleteslide.php?sid=<? echo $row['slide_id'];?>">delete</a></td>
	</tr>
	<tr class="<? echo (($counter % 2) == 0 ? "even" : "odd" );?>">
	<td colspan="3">
	<a href="../images/<?echo $row['folder'].'/'.$row['100xfile']; ?>">
		<img src="../images/<?echo $row['folder'].'/'.$row['100xfile']; ?>" width="180" /></a>
	<a href="../images/<?echo $row['folder'].'/'.$row['400xfile']; ?>">
		<img src="../images/<?echo $row['folder'].'/'.$row['400xfile']; ?>" width="180" /></a>
	<a href="../images/<?echo $row['folder'].'/'.$row['1000xfile']; ?>">
		<img src="../images/<? echo $row['folder'].'/'.$row['1000xfile']; ?>" width="180" class="last"/></a>
	</td></tr>
	<tr class="<? echo (($counter % 2) == 0 ? "even" : "odd" );?>"><td colspan="3" class="notes"><?echo $row['notes'];?></td></tr>
	<?
	$counter++;
	}?>
</table>
<?
include('./pagefoot.inc');
?>